﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="SysDefault_Manage.aspx.cs"
    Inherits="SYS_POPEDOM_SysDefault_Manage" %>

<%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>默认子系统</title>
    <link href="../css/PageStyle.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript" src="../JavaScript/Common.js"></script>
    <script type="text/javascript">
        function OnAfterEdit(grid) {
            var value = grid.record.data.IsDefault;
            var id = grid.record.data.SUB_SYSTEM;
            Ext.net.DirectMethods.OnAfterEdit(id, value);
        }
    </script>

</head>
<body>
    <form id="form1" runat="server">
    <ext:ResourceManager ID="ResourceManager1" runat="server" AjaxViewStateMode="Enabled" />
    <ext:Viewport ID="Viewport1" runat="server">
        <Content>
            <ext:BorderLayout ID="BorderLayout2" runat="server">
                <Center>
                    <ext:Panel runat="server" ID="Panel1" Border="false" Layout="FitLayout">
                        <Content>
                            <ext:GridPanel runat="server" ID="GridPanel1" AutoScroll="true" TrackMouseOver="true"
                                StripeRows="true">
                                <ColumnModel ID="ColumnModel1" runat="server">
                                    <Columns>
                                        <ext:Column Header="<center>子系统编号</center>" Width="80" DataIndex="SUB_SYSTEM" />
                                        <ext:Column Header="<center>子系统名称</center>" Width="150" DataIndex="SYSTEM_NAME" />
                                        <ext:Column Header="<center>默认登录</center>" Width="80" DataIndex="IsDefault">
                                            <Editor>
                                                <ext:ComboBox runat="server" ID="extcmb_IsDefault" Editable="false">
                                                    <Items>
                                                        <ext:ListItem Text="是" Value="是" />
                                                        <ext:ListItem Text="否" Value="否" />
                                                    </Items>
                                                </ext:ComboBox>
                                            </Editor>
                                        </ext:Column>
                                    </Columns>
                                </ColumnModel>
                                <View>
                                    <ext:GridView ID="GridView1" runat="server" MarkDirty="false" />
                                </View>
                                <Plugins>
                                    <ext:RowEditor ID="RowEditor1" runat="server" SaveText="确定" CancelText="取消" ClicksToEdit="1">
                                        <Listeners>
                                            <AfterEdit Fn="OnAfterEdit" />
                                        </Listeners>
                                    </ext:RowEditor>
                                </Plugins>
                                <Store>
                                    <ext:Store runat="server" ID="Store1" AutoLoad="true" OnRefreshData="OnRefresh_Data">
                                        <Proxy>
                                            <ext:PageProxy>
                                            </ext:PageProxy>
                                        </Proxy>
                                        <Reader>
                                            <ext:JsonReader>
                                                <Fields>
                                                    <ext:RecordField Name="SUB_SYSTEM" />
                                                    <ext:RecordField Name="SYSTEM_NAME" />
                                                    <ext:RecordField Name="IsDefault" />
                                                </Fields>
                                            </ext:JsonReader>
                                        </Reader>
                                    </ext:Store>
                                </Store>
                                <SelectionModel>
                                    <ext:RowSelectionModel ID="RowSelectionModel1" runat="server">
                                    </ext:RowSelectionModel>
                                </SelectionModel>
                            </ext:GridPanel>
                        </Content>
                    </ext:Panel>
                </Center>
            </ext:BorderLayout>
        </Content>
    </ext:Viewport>
    </form>
</body>
</html>
